package com.fyt.service.pasture;

import com.fyt.controller.utils.Result;
import com.fyt.dto.pasture.AddPastureDTO;
import com.fyt.dto.pasture.UpdatePastureDTO;
import com.fyt.entity.Pasture;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.transaction.annotation.Transactional;
import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author gdy
 * @since 2023-12-20
 */
@Transactional(rollbackFor = Exception.class)
public interface PastureService extends IService<Pasture> {
    /**
     * 牧场列表
     * @param map
     * @return
     */
    Result getPastureList(Map<String, String> map);

    /**
     * 获取停用的牧场
     * @param map
     * @return
     */
    Result getIsenablePastureList(Map<String, String> map);

    /**
     * 新增牧场
     * @param addPastureDto
     * @return
     */
    Result addPasture(AddPastureDTO addPastureDto);

    /**
     * 修改牧场
     * @param updatePastureDTO
     * @return
     */
    Result updatePasture(UpdatePastureDTO updatePastureDTO);
}
